package com.gxa.jjty.cjr.service.impl;

import com.gxa.jjty.cjr.mapper.EvaluateConfigMapper;
import com.gxa.jjty.cjr.service.EvaluateConfigService;
import com.gxa.jjty.core.pojo.EvaluateConfig;
import com.gxa.jjty.core.service.impl.BaseServiceImpl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import tk.mybatis.mapper.entity.Example;

import java.util.List;

/**
 * @ClassName EvaluateServiceImpl
 * @Author: ws
 * @date 2021/12/8 10:02
 */
@Service("evaluateConfigService")
public class EvaluateConfigServiceImpl extends BaseServiceImpl<EvaluateConfig> implements EvaluateConfigService {

    @Autowired
    EvaluateConfigMapper evaluateConfigMapper;

    @Override
    public List<EvaluateConfig> getListByTrue() {
        Example example = new Example(EvaluateConfig.class);
        Example.Criteria criteria = example.createCriteria();
        criteria.andEqualTo("state",true);

        List<EvaluateConfig> evaluateConfigs = evaluateConfigMapper.selectByExample(example);
        return evaluateConfigs;
    }

}
